<template>
<view class="container">
	<view class="chart-container">
	  <qiun-data-charts 
	    type="column"
	    :chartData="chartData"
	    :opts="chartOptions"
	    :canvas2d="true"
	  />
	</view>
</view>
</template>

<script>
export default {
  data() {
    return {
      chartData: {
        categories: ["衬衫", "羊毛衫", "雪纺衫", "裤子", "高跟鞋", "袜子"],
        series: [
          {
            name: "销量",
            data: [5, 20, 36, 10, 10, 20]
          }
        ]
      },
      chartOptions: {
        color: ["#2fc25b"],
        padding: [15, 15, 0, 15],
        enableScroll: false,
        legend: {
          show: false
        },
        xAxis: {
          disableGrid: true,
          axisLine: true,
          fontSize: 12
        },
        yAxis: {
          data: [
            { min: 0, max: 40 }
          ]
        },
        extra: {
          column: {
            type: "group",
            width: 30,
            meter: {
              border: 4,
              fillColor: "#1890FF"
            }
          }
        }
      }
    };
  }
};
</script>

<style>
.chart-container {
  width: 100%;
  height: 300px;
  padding: 10px;
  box-sizing: border-box;
}
</style>